Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Inventory][ECO] Show empty state when no entities are found. #193755

Merged
merged 5 commits into from
Sep 24, 2024

Conversation

kpatticha
Copy link
Contributor

@kpatticha kpatticha commented Sep 23, 2024

Summary

closes #193336

  • Introduce route GET /internal/inventory/has_data that check if there are any entities for hosts, services and containers
  • Show empty state
  • Refactor a bit the button to add data to reuse it

Note:

  • I used the illustration we had for the new service inventory as it had the dark version.
  • The callout will be shown by default. (I dismissed before starting the recording)

without entities

Screen.Recording.2024-09-23.at.18.59.31.mov

with entities

Screen.Recording.2024-09-23.at.19.20.04.mov

@kpatticha kpatticha requested a review from a team as a code owner September 23, 2024 16:31
@botelastic botelastic bot added the ci:project-deploy-observability Create an Observability project label Sep 23, 2024
@obltmachine
Copy link

🤖 GitHub comments

Expand to view the GitHub comments

Just comment with:

  • /oblt-deploy : Deploy a Kibana instance using the Observability test environments.
  • run docs-build : Re-trigger the docs validation. (use unformatted text in the comment!)

@kpatticha kpatticha added release_note:skip Skip the PR/issue when compiling release notes backport:prev-minor Backport to (8.x) the previous minor version (i.e. one version back from main) v8.16.0 labels Sep 23, 2024
Copy link
Contributor

@cauemarcondes cauemarcondes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, just some nits.

@kpatticha kpatticha enabled auto-merge (squash) September 24, 2024 15:38
@kibana-ci
Copy link
Collaborator

kibana-ci commented Sep 24, 2024

💛 Build succeeded, but was flaky

  • Buildkite Build
  • Commit: 0255766
  • Kibana Serverless Image: docker.elastic.co/kibana-ci/kibana-serverless:pr-193755-025576604c0e

Failed CI Steps

Test Failures

  • [job] [logs] FTR Configs #12 / aiops change point detection attaches change point charts to a dashboard

Metrics [docs]

Module Count

Fewer modules leads to a faster build time

id before after diff
inventory 189 198 +9

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
inventory 143.3KB 148.6KB +5.3KB
Unknown metric groups

ESLint disabled in files

id before after diff
inventory 2 3 +1

miscellaneous assets size

id before after diff
inventory 351.7KB 1.1MB ⚠️ +761.8KB

Total ESLint disabled count

id before after diff
inventory 2 3 +1

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

@kpatticha kpatticha merged commit 476b9f5 into elastic:main Sep 24, 2024
25 checks passed
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Sep 24, 2024
…c#193755)

## Summary

closes elastic#193336

- Introduce route `GET /internal/inventory/has_data` that check if there
are any entities for hosts, services and containers
- Show empty state
- Refactor a bit the button to add data to reuse it

**Note**:
- I used the illustration we had for the new service inventory as it had
the dark version.
- The callout will be shown by default. (I dismissed before starting the
recording)

### without entities

https://github.com/user-attachments/assets/6c5f7f38-a31c-4801-9e3d-3c91edd88f1d

### with entities

https://github.com/user-attachments/assets/19de8215-1c11-4c36-bae4-00432f205855

---------

Co-authored-by: kibanamachine <[email protected]>
(cherry picked from commit 476b9f5)
@kibanamachine
Copy link
Contributor

💚 All backports created successfully

Status Branch Result
8.x

Note: Successful backport PRs will be merged automatically after passing CI.

Questions ?

Please refer to the Backport tool documentation

kibanamachine added a commit that referenced this pull request Sep 24, 2024
…193755) (#193904)

# Backport

This will backport the following commits from `main` to `8.x`:
- [[Inventory][ECO] Show empty state when no entities are found.
(#193755)](#193755)

<!--- Backport version: 9.4.3 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sqren/backport)

<!--BACKPORT
[{"author":{"name":"Katerina","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-09-24T17:15:26Z","message":"[Inventory][ECO]
Show empty state when no entities are found. (#193755)\n\n##
Summary\r\n\r\ncloses #193336 \r\n\r\n\r\n- Introduce route `GET
/internal/inventory/has_data` that check if there\r\nare any entities
for hosts, services and containers\r\n- Show empty state\r\n- Refactor a
bit the button to add data to reuse it\r\n\r\n**Note**:\r\n- I used the
illustration we had for the new service inventory as it had\r\nthe dark
version.\r\n- The callout will be shown by default. (I dismissed before
starting the\r\nrecording)\r\n\r\n### without
entities\r\n\r\nhttps://github.com/user-attachments/assets/6c5f7f38-a31c-4801-9e3d-3c91edd88f1d\r\n\r\n###
with
entities\r\n\r\n\r\nhttps://github.com/user-attachments/assets/19de8215-1c11-4c36-bae4-00432f205855\r\n\r\n---------\r\n\r\nCo-authored-by:
kibanamachine
<[email protected]>","sha":"476b9f5ba767d391236cd026da13fd939863abe1","branchLabelMapping":{"^v9.0.0$":"main","^v8.16.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","v9.0.0","backport:prev-minor","ci:project-deploy-observability","v8.16.0"],"title":"[Inventory][ECO]
Show empty state when no entities are
found.","number":193755,"url":"https://github.com/elastic/kibana/pull/193755","mergeCommit":{"message":"[Inventory][ECO]
Show empty state when no entities are found. (#193755)\n\n##
Summary\r\n\r\ncloses #193336 \r\n\r\n\r\n- Introduce route `GET
/internal/inventory/has_data` that check if there\r\nare any entities
for hosts, services and containers\r\n- Show empty state\r\n- Refactor a
bit the button to add data to reuse it\r\n\r\n**Note**:\r\n- I used the
illustration we had for the new service inventory as it had\r\nthe dark
version.\r\n- The callout will be shown by default. (I dismissed before
starting the\r\nrecording)\r\n\r\n### without
entities\r\n\r\nhttps://github.com/user-attachments/assets/6c5f7f38-a31c-4801-9e3d-3c91edd88f1d\r\n\r\n###
with
entities\r\n\r\n\r\nhttps://github.com/user-attachments/assets/19de8215-1c11-4c36-bae4-00432f205855\r\n\r\n---------\r\n\r\nCo-authored-by:
kibanamachine
<[email protected]>","sha":"476b9f5ba767d391236cd026da13fd939863abe1"}},"sourceBranch":"main","suggestedTargetBranches":["8.x"],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/193755","number":193755,"mergeCommit":{"message":"[Inventory][ECO]
Show empty state when no entities are found. (#193755)\n\n##
Summary\r\n\r\ncloses #193336 \r\n\r\n\r\n- Introduce route `GET
/internal/inventory/has_data` that check if there\r\nare any entities
for hosts, services and containers\r\n- Show empty state\r\n- Refactor a
bit the button to add data to reuse it\r\n\r\n**Note**:\r\n- I used the
illustration we had for the new service inventory as it had\r\nthe dark
version.\r\n- The callout will be shown by default. (I dismissed before
starting the\r\nrecording)\r\n\r\n### without
entities\r\n\r\nhttps://github.com/user-attachments/assets/6c5f7f38-a31c-4801-9e3d-3c91edd88f1d\r\n\r\n###
with
entities\r\n\r\n\r\nhttps://github.com/user-attachments/assets/19de8215-1c11-4c36-bae4-00432f205855\r\n\r\n---------\r\n\r\nCo-authored-by:
kibanamachine
<[email protected]>","sha":"476b9f5ba767d391236cd026da13fd939863abe1"}},{"branch":"8.x","label":"v8.16.0","branchLabelMappingKey":"^v8.16.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->

Co-authored-by: Katerina <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:prev-minor Backport to (8.x) the previous minor version (i.e. one version back from main) ci:project-deploy-observability Create an Observability project release_note:skip Skip the PR/issue when compiling release notes v8.16.0 v9.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Inventory] Handle empty states
5 participants